import type { Metadata } from 'next';
import { Inter } from 'next/font/google';
import './globals.css';
import { NextIntlClientProvider } from 'next-intl';
import { getMessages } from 'next-intl/server';

const inter = Inter({ subsets: ['latin'] });

export const metadata: Metadata = {
  title: 'IdeaForge - AI-Powered Business Plan Generator',
  description: 'Transform your ideas into comprehensive business plans with AI assistance',
  keywords: ['business plan', 'AI', 'startup', 'entrepreneurship', 'strategy'],
  authors: [{ name: 'IdeaForge Team' }],
  creator: 'IdeaForge',
  publisher: 'IdeaForge',
  formatDetection: {
    email: false,
    address: false,
    telephone: false,
  },
  metadataBase: new URL('https://ideaforge.io'),
  openGraph: {
    title: 'IdeaForge - AI-Powered Business Plan Generator',
    description: 'Transform your ideas into comprehensive business plans with AI assistance',
    url: 'https://ideaforge.io',
    siteName: 'IdeaForge',
    images: [
      {
        url: '/og-image.png',
        width: 1200,
        height: 630,
        alt: 'IdeaForge - AI-Powered Business Plan Generator',
      },
    ],
    locale: 'en_US',
    type: 'website',
  },
  twitter: {
    card: 'summary_large_image',
    title: 'IdeaForge - AI-Powered Business Plan Generator',
    description: 'Transform your ideas into comprehensive business plans with AI assistance',
    images: ['/og-image.png'],
  },
  robots: {
    index: true,
    follow: true,
    googleBot: {
      index: true,
      follow: true,
      'max-video-preview': -1,
      'max-image-preview': 'large',
      'max-snippet': -1,
    },
  },
  verification: {
    google: 'your-google-verification-code',
  },
};

export default async function RootLayout({
  children,
  params: { locale },
}: {
  children: React.ReactNode;
  params: { locale: string };
}) {
  const messages = await getMessages();

  return (
    <html lang={locale} suppressHydrationWarning>
      <body className={inter.className}>
        <NextIntlClientProvider messages={messages}>
          {children}
        </NextIntlClientProvider>
      </body>
    </html>
  );
} 